package com.blue.seata.storage.controller;

import com.blue.seata.common.JsonResult;
import com.blue.seata.storage.service.StorageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @author liulei
 * @version 1.0
 */
@RestController
@RequestMapping("test")
public class StorageController {

    @Autowired
    private StorageService service;

    @RequestMapping(value = "minus", method = RequestMethod.GET)
    public JsonResult minus(@RequestParam String code, @RequestParam Integer count) {
        service.minus(code, count);
        return JsonResult.ok();
    }
}
